<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ page isELIgnored="false"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<!DOCTYPE html>
<%
	String path = request.getContextPath();
%>
<html>
<head>

<link rel="stylesheet" type="text/css"
	href="<%=path%>/script/easyUI-1.4/themes/bootstrap/easyui.css">
<link rel="stylesheet" type="text/css"
	href="<%=path%>/script/easyUI-1.4/themes/icon.css">
<script type="text/javascript"
	src="<%=path%>/script/easyUI-1.4/jquery-3.2.1.min.js"></script>
<script type="text/javascript"
	src="<%=path%>/script/easyUI-1.4/jquery.easyui.min.js"></script>
<script type="text/javascript"
	src="<%=path%>/script/easyUI-1.4/locale/easyui-lang-zh_CN.js"></script>
<style>
ul {
	list-style-type: none;
	margin: 0;
	padding: 0;
	overflow: hidden;
	border: 1px solid #e7e7e7;
	background-color: #f3f3f3;
}

li {
	float: left;
}

li a {
	display: block;
	color: #666;
	text-align: center;
	padding: 14px 16px;
	text-decoration: none;
}



</style>

<script type="text/javascript">


	function myLib(){
		$("#myLib").css("background-color","#A1A1A1");
		$("#localLib").css("background-color","#f3f3f3");
		$("#friend").css("background-color","#f3f3f3");
		$("#other").css("background-color","#f3f3f3");
		var key = $("#key").val();	
		$("#searchIframe").attr("src","<%=path%>/userAction/search?type=myLib&key="+key);
	}
	
	function localLib(){
		$("#localLib").css("background-color","#A1A1A1");
		$("#friend").css("background-color","#f3f3f3");
		$("#myLib").css("background-color","#f3f3f3");
		$("#other").css("background-color","#f3f3f3");
		var key = $("#key").val();	
		$("#searchIframe").attr("src","<%=path%>/userAction/search?type=localLib&key="+key);
	}
	
	function friend(){
		$("#friend").css("background-color","#A1A1A1");
		$("#myLib").css("background-color","#f3f3f3");
		$("#localLib").css("background-color","#f3f3f3");
		$("#other").css("background-color","#f3f3f3");
		var key = $("#key").val();	
		$("#searchIframe").attr("src","<%=path%>/userAction/search?type=friend&key="+key);
	}
	
	function other(){
		$("#other").css("background-color","#A1A1A1");
		$("#myLib").css("background-color","#f3f3f3");
		$("#localLib").css("background-color","#f3f3f3");
		$("#friend").css("background-color","#f3f3f3");
		var key = $("#key").val();	
		$("#searchIframe").attr("src","<%=path%>/userAction/search?type=other&key="+key);
	}
</script>
</head>




<body class="easyui-layout" >
	
	<div data-options="region:'center'">
	<div style="margin-left: 80px; margin-top: 20px;">
		<input class="easyui-textbox" id="key"
			data-options="iconCls:'icon-search',prompt:'搜索'"
			style="width: 600px; height: 35px;">
	</div>
	<div>
		<ul style="margin-left: 80px;margin-top: 20px;width: 60%">
			<li><a id="myLib"  onclick="myLib();">我的图书馆文章</a></li>
			<li><a id="localLib"  onclick="localLib();">全站文章</a></li>
			<li><a id="friend"  onclick="friend();">馆友</a></li>
			<li><a id="other"  onclick="other();">站外搜索</a></li>
		</ul>
	</div>
	
	<div style="margin-left: 80px;margin-top: 20px;height: 1024px;">
		<iframe scrolling="auto" application="yes" frameborder="0" style="width:100%;height:100%;" id="searchIframe"></iframe>
	</div>
	</div>
</body>

</html>